import React, { memo } from "react";
import cs from "classnames";
import sty from "./sty.module.css";
import { getSizeImage } from "@/utils/format-utils";
const AlbumCover = memo((props) => {
  const { info } = props;
  return (
    <div className={sty.root}>
      <div className={sty.image}>
        <img src={getSizeImage(info.picUrl, 100)} alt={info.name} />
        <span className={cs(sty.cover, "image_cover", "no-link")}>
          {info.name}
        </span>
      </div>
      <div className={cs(sty.name, "txt1")}>{info.name}</div>
      <div className={cs(sty.artist, "txt1")}>{info.artist.name}</div>
    </div>
  );
});
export default AlbumCover;
